<html>
<head>
    <title>Laporan Formulir</title>
</head>
<style type="text/css" media="all">
*{
	font-size:11px;
	font-family:Arial, Helvetica, sans-serif;	
}
table.data{border-collapse:collapse; margin-top:10px; border:1px solid #999;}
table.data tr th{
	padding:3px;
	background-color:#ddd;		
}
table.data tr td{
	font-size:10px;
	vertical-align:text-top;
	border-bottom:1px solid #999;
}
</style>
<body>
<img src="<?php echo themeUrl(); ?>images/logo.png" width="70px" align="left" />
<p style="float:left;">
	<b style="font-size:16px;">REALIZATION OF PRODUCTION</b>
	<br />
    <b>Period <?php echo myDate($this->jCfg['isearch']['start_date'],"d M Y",FALSE);?> s.d <?php echo myDate($this->jCfg['isearch']['end_date'],"d M Y",FALSE);?></b>
</p>
<div style="clear:both;"></div>
<table class="data" width="2000px">
	<tr>
    	<th>No</th>
        <th>No. Bong/Bg/Policy</th>
        <th>Class Of Bussiness</th>
        <th>Client Name</th>
        <th>Marketing</th>
        <th>Occupation</th>
        <th>Effective Date</th>
        <th>Expire Date</th>
        <th>Days</th>
        <th>Currency</th>
        <th>Total Sum Insured</th>
        <th>Kurs</th>
        <th>Bond Amount (Rp)</th>
        <th>Clients Rate</th>
        <th>Premium To Clients</th>
        <th>Stamp Duty / Policy Fee</th>
        <th>Total Premium To Clients</th>
        <th>Ins/Bank Rate</th>
        <th>Premium to Ins/Bank</th>
        <th>Stamp duty</th>
        <th>Policy Fee / Provision</th>
        <th>Adm (As.)</th>
        <th>Adm (Bank.)</th>
        <th>Notaril</th>
        <th>Total</th>
        <th>Comission</th>
        <th>Net Brokerage</th>
        <th>Bank Penerbit</th>
        <th>Status</th>
    </tr>
    <?php if(count($data) > 0){
			foreach($data as $r){	
	?>
    	<tr>
    		<td><?php echo ++$no;?></td>
            <td><?php echo $r->form_no_bank_garansi;?></td>
            <td><?php echo $r->form_bank_garansi_type;?></td>
            <td><?php echo $r->form_obligee_name;?></td>
            <td><?php echo $r->marketing_name;?></td>
            <td><?php echo $r->form_job;?></td>
            <td><?php echo myDate($r->form_start_date,"d M Y",FALSE);?></td>
            <td><?php echo myDate($r->form_end_date,"d M Y",FALSE);?></td>
            <td><?php echo $r->form_as_long_day;?></td>
            <td><?php echo $r->cur_code;?></td>
            <td><?php echo number_format($r->form_guarantee_value,0,",",".");?></td>
            <td><?php echo $r->cur_value_per_rupiah;?></td>
            <td><?php echo myNum($r->form_guarantee_value * $r->cur_value_per_rupiah);?></td>
            <td><?php echo $r->form_client_rate * 100;?> %</td>
            <td><?php echo number_format($r->form_biaya_ditagihkan_ke_client,0,",",".");?></td>
            <td><?php echo number_format($r->form_biaya_notaril + $r->form_biaya_adm,0,",",".");?></td>
            <td><?php echo number_format($r->form_biaya_notaril + $r->form_biaya_adm + $r->form_biaya_ditagihkan_ke_client,2,",",".");?></td>
            <td> <?php echo $r->form_rate_bank * 100;?> % </td>
            <td><?php echo number_format($r->form_jasa_penjamin,0,",",".");?></td>
            <td><?php echo number_format($r->form_bea_materai,0,",",".");?></td>
            
            <td><?php echo number_format($r->form_biaya_provisi,0,",",".");?></td>
            <td><?php echo number_format($r->form_biaya_administrasi,0,",",".");?></td>
            <td><?php echo number_format($r->form_biaya_adm_asuransi,0,",",".");?></td>
            <td><?php echo number_format($r->form_biaya_notaril_asuransi,0,",",".");?></td>
            <td>
			<?php 
				$total = $r->form_jasa_penjamin + $r->form_bea_materai + $r->form_biaya_provisi + $r->form_biaya_administrasi + $r->form_biaya_adm_asuransi + $r->form_biaya_notaril_asuransi;
				echo number_format($total,0,",",".");
			;?>
            </td>
            <td><?php echo number_format($r->form_komisi,0,",",".");?></td>
            <td><?php echo number_format(($r->form_biaya_notaril + $r->form_biaya_adm + $r->form_biaya_ditagihkan_ke_client)-$total,2,",",".");?></td>
            <td><?php echo getBankName($r->form_bank_penerbit);?></td>
            <td align="center" ><?php echo ($r->form_status=='DONE')?'&radic;':'';?></td>
            </tr>
    <?php } 
		}
	?>
</table>

<table style="width:600px; margin-top:50px;" border="0">
	<tr>
    	<td align="center" width="350px"><u><b>Wiwin Tri S.</b></u><br>Admin Spv</td>
        <td align="center" width="350px"><u><b>Fajar R. Sawarno</b></u><br>GM Marketing</td>
        <td align="center" width="350px"><u><b>Maizar Ismail</b></u><br>GM Finance</td>
    </tr>
</table>
</body>
</html>